<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@include file="../util/makerAndenterGoodAndselect1.jsp"%>
<%--
  Created by IntelliJ IDEA.
  User: id
  Date: 2021/1/25
  Time: 10:21
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ page  isELIgnored="false" contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Show Tracking</title>
    <style type="text/css">
        /*进货订单*/
        #center{
            width: 1288px;
            height:60px;
            position: absolute;
            top: 60px;
            left: 83px;

        }

        /*from表单*/
        .ctop{
            position: relative;
            left: 44px;
            top: 10px;
            border-radius: 10px;
            width: 1200px;
            height: 40px;
            box-sizing: border-box;
            padding-top: 5px;
            padding-left: 15px;
            border: 1px solid paleturquoise;
        }

        #tab{
            box-sizing: border-box;
            padding-left: 96px;
            width: 1300px;
            height: 300px;
            position: absolute;
            top: 115px;
            left: 2px;
        }
        .p{
            float: left;
            width: 55px;
            text-align: center;
            height: 40px;
        }
        .p:hover{
            background-color: rgb(192,192,192);
        }
    </style>
    <script type="text/javascript" src="../../../static/jquery-3.4.1.js"></script>
    <script type="text/javascript">
        $(function () {
            $("#tab").hover(function () {
                $("#d4").hide()
                $("#xs").hide()
                $("#d3").hide()
                $("#d4").hide()
            })
        })
    </script>
</head>
<body>
<!--************************************************************************************************************************-->
<!--查询的文本框上半部分-->
<div id="center">
    <!--上面部分的查询-->
    <div class="ctop">
        <form action="${pageContext.request.contextPath}/Tracking/findAllByTr">
            <!--根据订单编号查-->
            <input type="text" name="document1" placeholder="根据客户查询" style="width: 230px;border-radius: 6px;height: 1.7em;text-indent: 1em" value="${document1}">
            <input type="submit" value="搜索" style="width: 90px;height: 2em;background-color: rgb(64,158,244);border-radius: 6px">
        </form>
    </div>

    <div id="tab">
        <table style="width: 1100px;height: 180px;text-align: center" border="1" >
            <tr>
                <td>订单编号</td>
                <td>业务日期</td>
                <td>客户名称</td>
                <td>商品类型</td>
                <td>商品名称</td>
                <td>商品数量</td>
                <td>处理状态</td>
                <td>TIME</td>
            </tr>
            <c:forEach var="list" items="${page.list}">
                <tr>
                    <td>${list.document1}</td>
                    <td>
                        <fmt:formatDate value="${list.datat}" pattern="yyyy/MM/dd "/>
                    </td>
                    <td>
                       ${list.forname2}
                    </td>
                    <td>${list.goodstyle}</td>
                    <td>${list.goods}</td>
                    <td>${list.num}</td>
                    <td>
                        <c:if test="${list.okandno==0}">
                            已发货
                        </c:if>
                        <c:if test="${list.okandno==1}">
                           <span style="color: red">已退货</span>
                        </c:if>
                    </td>
                    <td>约${list.numdata}天达到${list.whe2}</td>
                </tr>
            </c:forEach>
        </table>


        <%--page--%>
        <div id="pa" style="width: 500px;height: 50px;margin-top: 30px">
            <div class="p">
                <a href="${pageContext.request.contextPath}/Tracking/findAllByTr?start=${page.curryPage-1}&document1=${document1}">上一页</a>
            </div>
            <c:forEach begin="1" end="${page.totalPae}" var="a">
                <div class="p">
                    <a href="${pageContext.request.contextPath}/Tracking/findAllByTr?start=${a}&document1=${document1}">${a}</a>
                </div>
            </c:forEach>


            <div class="p">
                <a href="${pageContext.request.contextPath}/Tracking/findAllByTr?start=${page.curryPage+1}&document1=${document1}">下一页</a>
            </div>

            <div class="p" style="width: 200px">
                <span>第${page.curryPage}/${page.totalPae}页</span>
                <span>共${page.totalCount}条记录,</span>
            </div>
        </div>
    </div>
</div>


